/*

* ------------------------------------------------------------------------
* ------------------------------------------------------------------------
* |     Smart-Shop开源商城系统/ Java商城-首选电商平台系统 请务必保留此注释头信息
* |     开源地址: https://gitee.com/ningbo-qishan/gruul-mall
* ------------------------------------------------------------------------
* ------------------------------------------------------------------------
* |     可正常分享和学习源码,未经授权 不可商用！
* |     商业版中台购买/开源版商业授权 联系技术客服
* |     官网:  https://www.73app.cn/
* ------------------------------------------------------------------------
* ------------------------------------------------------------------------
* |     Copyright (c) 2016-2999 宁波启山智软科技有限公司
* |     版权所有 ,侵权必究！
* ------------------------------------------------------------------------

*/
package com.medusa.gruul.platform.model.dto.agent;

import com.medusa.gruul.platform.model.dto.agent.AgentRuleDto;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.hibernate.validator.constraints.Range;

import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;
import java.math.BigDecimal;
import java.util.List;

/**
 * @author whh
 * @description
 * @data: 2020/10/22
 */
@Data
public class BatchOptionDto {

    @ApiModelProperty(value = "操作类型 type=1 设置折扣  type=2批量设置目标  type=3 批量启用代理  type=4 批量停用代理  type=5批量删除 type=6 迁移渠道商  type=7迁移商户")
    @Range(max = 5, min = 4, message = "操作类型操作")
    @NotNull(message = "操作类型操作")
    private Integer optionType;

    @ApiModelProperty(value = "代理目标  type=2")
    @Size(min = 2, max = 2, message = "代理目标错误")
    private List<AgentRuleDto> agentTarget;


    @ApiModelProperty(value = "折扣%  type=1")
    @Range(max = 100, min = 0, message = "折扣超出范围")
    private BigDecimal discount;

    @ApiModelProperty(value = "代理id数组  type = 1 2 3 4 5")
    private List<Long> agentIds;

    @ApiModelProperty(value = "渠道商id数组  type=6")
    @Size(min = 1, message = "渠道商未选择")
    private List<Long> channelIds;

    @ApiModelProperty(value = "商户id数组  type=7")
    @Size(min = 1, message = "商户未选择")
    private List<Long> accountIds;

    @ApiModelProperty(value = "代理id  type=6 || type=7")
    private Long agentId;
}
